home *** CD-ROM | disk | FTP | other *** search
/ Internet Info 1994 March / Internet Info CD-ROM (Walnut Creek) (March 1994).iso / answers / comp / text-faq < prev    next >
Text File  |  1994-04-11  |  31KB  |  690 lines

  1. Newsgroups: comp.text,news.answers,comp.answers
  2. Path: bloom-beacon.mit.edu!hookup!swrinde!cs.utexas.edu!utnut!torn!uunet.ca!uunet.ca!ecicrl!clewis
  3. From: clewis@ferret.ocunix.on.ca (Chris Lewis)
  4. Subject: comp.text Frequently Asked Questions
  5. Summary: Discussions on text processing in general, and troff in particular
  6. Message-ID: <textfaq_766070404@ferret.ocunix.on.ca>
  7. Supersedes: <textfaq_764173205@ferret.ocunix.on.ca>
  8. Approved: news-answers-request@mit.edu
  9. Date: Mon, 11 Apr 1994 13:20:08 GMT
  10. Expires: Tue, 17 May 1994 13:20:04 GMT
  11. Reply-To: textfaq@ferret.ocunix.on.ca (Text FAQ commentary reception)
  12. Organization: Elegant Communications Inc., Ottawa, Canada
  13. Keywords: typesetting troff groff ditroff wysiwyg sgml word desktop dwb
  14. Followup-To: poster
  15. Lines: 672
  16. Xref: bloom-beacon.mit.edu comp.text:2418 news.answers:17907 comp.answers:4859
  17.  
  18. Archive-name: text-faq
  19. Last-Modified: Sat Mar 19 21:56:40 EST 1994
  20.  
  21.         Frequently Asked Questions for comp.text
  22.                Chris Lewis
  23.  
  24.            Copyright 1991 - 1994.
  25.  
  26.         Redistribution for profit, or with altered
  27.         content/format prohibited without permission
  28.         of the author.  Any other redistribution must
  29.         include this copyright notice and attribution.
  30.  
  31. (This list was originally compiled by Nils-Peter Nelson, with
  32. contributions from Jaap Akkerhuis, Dick Dunn, Nick Haines, Steve
  33. Harley, Harro Kremer, Chris Lewis, John Macdonald, Bob Morris,
  34. Nils-Peter Nelson, Chip Rosenthal.)
  35.  
  36. If you have comments or additions, please contact Chris Lewis,
  37. textfaq@ferret.ocunix.on.ca (note Reply-to).
  38.  
  39. Changes are marked with a "|" in left column.  Many newsreaders
  40. (e.g. rn, trn) allow you to search for them with "g^|".
  41.  
  42. Changes this issue: Source for Adobe Transcript.
  43.             Online Troff manual availability.
  44.  
  45. ------------------------------
  46. Subject: Questions discussed:
  47.  
  48. General interest:
  49.  
  50.   GN1. What is the difference between word processing, desktop
  51.          publishing, technical publishing, electronic publishing, etc?
  52.   GN2. Which do I need?
  53.   GN3. What is a markup language?
  54.   GN4. What is SGML? ODA?
  55.   GN5. What is WYSIWYG? Do I need it?
  56.   GN6. What is PostScript?
  57.   GN7. What is TeX?
  58.   GN8. What are some popular Desktop Publishing packages?
  59.   GN9. Where can I read more?
  60.   GN10. What is Lout?
  61.  
  62. Specific to troff:
  63.  
  64.   TR1. What is troff? Why are there so many questions about it?
  65.   TR2. How many varieties of troff are there? What are the differences?
  66.   TR3. What are some of the filters for troff output?
  67.   TR4. What other troff printer drivers are there?
  68.   TR5. How do I get my troff to drive my printer?
  69.   TR6. None of the mentioned packages support *my* printer.  Help?
  70.   TR7. How to I embed PostScript in troff?
  71.   TR8. What are fonts?  How do I add fonts?
  72.   TR9. What are width tables?
  73.   TR10. How do I make width tables?
  74.   TR11. What are: pic, eqn, tbl, grap, refer?
  75.   TR12. How do I preview my troff on my screen?
  76.   TR13. I need makedev, but my DWB doesn't come with it.
  77.   TR14. How can I get nroff/troff for DOS?
  78.   TR15. What books can I get about DWB?
  79.  
  80. khe discussions below are organized in digest-form, so you may
  81. scan ahead for "^Subject:" to move from one topic to the next
  82. (the ^G command does this in rn), and you may search for "^Subject: GN5"
  83. (for example) to jump to the discussion of a particular question.
  84. (The caret "^" before "Subject" is a convention of regular expressions
  85. that restricts the search to match only at the beginning of a line.)
  86.  
  87. ------------------------------
  88. Subject: GN1. What is the difference between word processing, desktop
  89.     publishing, technical publishing, electronic publishing, etc?
  90.  
  91. Electronic Publishing is an all-encompassing term that means
  92. using computers (instead of hot lead) to set type for
  93. documents.  Although publishing includes a sequence of
  94. processes right through distribution, EP tends to emphasize
  95. document composition through production of a single master copy.
  96.  
  97. It is helpful to picture a graph with "complexity" along
  98. the X axis and "length" along the Y axis.  Complexity
  99. varies from straight text to footnotes and indexing to
  100. tables to line drawings to gray-scale illustration to
  101. full color.  Length varies from 1 page to 10,000 or more
  102. (better make the Y axis logarithmic!)
  103.  
  104. Word processing dominates the lower left of the graph
  105. (business letters).  Desktop publishing dominates the lower
  106. right (advertising layout).  Host-based text formatters like
  107. troff, TeX and Scribe dominate the upper-left (phone book).
  108. Proprietary systems have traditionally dominated the upper
  109. right (Sears catalog, encyclopedia); these are being supplanted
  110. by hybrids consisting of pieces from the other segments.
  111.  
  112. The middle of the graph is fair ground for everyone but is
  113. increasingly the domain of Technical Publication systems like
  114. Interleaf and FrameMaker.
  115.  
  116. ------------------------------
  117. Subject: GN2. Which do I need?
  118.  
  119. Word processors and Desktop publishers are more than adequate
  120. for documents of tens of pages.  Because they are mostly
  121. limited to PC's and Macintosh, they may be impediments in
  122. producing long documents, which would have to be done in
  123. digestible chunks (say, a chapter at a time).  High-end systems
  124. are usually UNIX-based, which means computer power and document
  125. capacity are limited only by how much you want to spend.
  126.  
  127. ------------------------------
  128. Subject: GN3. What is a markup language?
  129.  
  130. All formatters need to distinguish the text to be printed
  131. from instructions about how to print; the latter is called
  132. markup.  Procedural markup tells the software what to do
  133. (space down, invoke a macro); generic markup describes the
  134. thing to be printed (heading, cross-reference, etc.)  Troff
  135. and TeX are examples of procedural markups; ODA and SGML
  136. prescribe rules for generic languages; and good macro packages
  137. for troff or TeX make them, more-or-less, generic markup
  138. languages.
  139.  
  140. Many of the word processing packages (such as Word or Wordstar)
  141. can only do procedural markup - the software is told by the
  142. user "how to display it", rather than "what this is" - and leaving
  143. the visual representation to preprogrammed rule sets (ie:
  144. macros) - see GN5.
  145.  
  146. ------------------------------
  147. Subject: GN4. What is SGML? ODA?
  148.  
  149. SGML is the Standard Generalized Markup Language.  SGML is defined
  150. in International Standard ISO 8879:1986.  SGML is a language for
  151. formally describing the structure and contents of documents.  SGML
  152. is also the syntax used by documents so described.
  153.  
  154. SGML is an important move in the direction of separating information
  155. from its presentation, e.g. making different presentations possible
  156. for the same information.  The better macro packages for TeX and
  157. troff attempt to do the same thing.  This is in contrast with WYSIWYG -
  158. see GN5.
  159.  
  160. SGML is more fully discussed in comp.text.sgml.
  161.  
  162. SGML is the name of a directory at the public FTP site ftp.ifi.uio.no
  163. where you can find a (draft) FAQ, a bibliography, and more information.
  164.  
  165. ODA: Office [Open] Document Architecture, takes a similar approach
  166. but stresses blind interchange.  ODA is defined in the multi-part
  167. standard ISO 8613:1988, in the CCITT T.410 series recommendations,
  168. and in ECMA standard 101.
  169.  
  170. ------------------------------
  171. Subject: GN5. What is WYSIWYG? Do I need it?
  172.  
  173. What-you-see-is-what-you-get: essential for advertising layout,
  174. but a useless time-waster for a phone book.  WYSIWYG is the
  175. opposite of SGML, in that in SGML you know what something
  176. is (say, a chapter heading) but you don't know what it looks
  177. like; in WYSIWYG you know what it looks like but you don't
  178. know what it is.  The obvious benefit of WYSIWYG is that the
  179. author is aware at all times of the final appearance of the
  180. document; the liability is that the vendor gets to choose the
  181. internal representation of the document, and may not tell you
  182. what it is.
  183.  
  184. The best trade-off would be a WYSIWYG system with a well-documented,
  185. usable markup language.  There is a system called "GRIF" which
  186. supposedly supports SGML and WYSIWYG which is possibly available.
  187. the "doc" program in Interviews is a freeware UNIX WYSIWYG
  188. wordprocessor.
  189.  
  190. We should caution that few of the self-proclaimed WYSIWYG systems
  191. actually show the exact same thing on screen as you get on a printer:
  192. What You See Is Sort Of Like What You Get.  When 300 dpi, 17 inch
  193. terminals are common true WYSIWYG will be practical.
  194.  
  195. Being aware of the final appearance of a document is not universally
  196. accepted as a "good thing", Robertson Davies has suggested that the
  197. WYSIWYG approach to writing contributes to "blather" (and he should
  198. know as a past master ;-), while others have argued that the final
  199. appearance can't always be known.  WYSIWYG processors tend to
  200. encourage an approach that makes re-use and re-packaging of
  201. documents for alternate methods of presentation (eg: on-line
  202. and paper documentation) difficult.  Efficiency studies have shown,
  203. for at least certain types of documentation, that documents are
  204. written faster with text processors than WYSIWYGS.
  205.  
  206. ------------------------------
  207. Subject: GN6. What is PostScript?
  208.  
  209. PostScript is a language for output devices.  It does for output
  210. devices what Unix does for processors, viz., it allows a common
  211. software interface despite differences in hardware platform.
  212. PostScript controllers exist for paper printers from 4 pages
  213. per minute up to 92 ppm, from 300 dots per inch to over 6000 dpi
  214. typesetter, and for film recorders, color printers and X Window
  215. terminals.  Without PostScript, every text formatter has to
  216. understand the idiosyncrasies of every vendor's hardware.
  217. See comp.lang.PostScript for more.  PostScript is a registered
  218. trademark of Adobe Corporation.
  219.  
  220. ------------------------------
  221. Subject: GN7. What is TeX?
  222.  
  223. TeX is a batch formatter similar to troff developed by Don Knuth
  224. at Stanford.  It is most popular in universities and is freely
  225. traded because of the lack of licensing restrictions. ArborText
  226. sells a commercial version for big and small (ie PC's) machines.
  227. There are various versions for PC-class machines. LaTeX (Leslie
  228. Lamports version of TeX) is a more friendly version of the same
  229. formatter. It does for TeX what macros does for troff.  See
  230. comp.text.tex for TeX FAQs.
  231.  
  232. [To be pedantically correct, there are really only very few versions
  233. of TeX.  However, the relationship between the formatter and
  234. the macro sets (e.g.: LaTeX) is considerably more blurry in TeX than
  235. troff, and the macro package tends to be compiled-into different
  236. instantiations of TeX.  This is truly part of the culture - TeXies
  237. refer to "latex documents", troffers more generally refer to
  238. "troff with mm macros".  It's confusing.]
  239.  
  240. Oh, and to save yourself sounding like an idiot, the "eX" in "TeX"
  241. is pronounced so that it rhymes with "blecchh", not "sex" (the
  242. X is a greek chi).
  243.  
  244. ------------------------------
  245. Subject: GN8. What are some popular Desktop Publishing packages?
  246.  
  247. Aldus practically invented Desktop publishing with "PageMaker".
  248. Ventura is the largest selling of the high-end PC packages.
  249.  
  250. WordPerfect and Word are lower in functionality but less
  251. expensive and exist on both DOS and Macintosh.  These are
  252. essentially word-processing packages rather than Desktop
  253. Publishing.
  254.  
  255. See comp.text.desktop for more information. Interleaf
  256. and FrameMaker are workstation-based and are higher in
  257. price and functionality, and require more substantial
  258. machine resources, but give you more in return.  FrameMaker
  259. is now available for Windows 3.1, giving transportability
  260. between the DOS/Windows, Mac and UNIX world.  See comp.text.desktop,
  261. comp.text.frame and comp.text.interleaf.
  262.  
  263. ------------------------------
  264. Subject: GN9. Where can I read more?
  265.  
  266. Publish!, Business Publishing and Seybold Report are all
  267. excellent journals for keeping up to date.  There are
  268. books devoted to most of the major packages, too many
  269. to mention here.
  270.  
  271. Richard Rubinstein's book "Digital Typography", Addison-Wesley
  272. is apparently a readable book that goes into the details of
  273. composition systems, fonts and reproduction.
  274.  
  275. -------------------------------
  276. Subject: GN10. What is Lout?
  277.  
  278. Lout is a new batch formatter drawing a fair bit from TeX and troff.
  279. Its main strengths are a more powerful and much easier to use "macro"
  280. programming language, and is reputed to be as "complete" as TeX or
  281. the troff formatting suite.  It only generates PostScript.
  282.  
  283. Lout was written by Jeff Kingston (jeff@cs.su.oz.au) and
  284. is available via anon FTP from ftp.cs.su.oz.au directory "jeff".
  285.  
  286. ------------------------------
  287. Subject: TR1. What is troff? Why are there so many questions about it?
  288.  
  289. Troff is one of the oldest text formatters in existence. Because
  290. it was distributed as part of the Unix operating system for
  291. many years, it is by default on several hundred thousand machines,
  292. far more than any other Unix text formatter.  It originated
  293. in AT&T Bell Laboratories in 1971 and its author was Joseph
  294. Ossanna.  Its legitimate father was a program called runoff,
  295. written at MIT in the 1960's.
  296.  
  297. Because there is no comp.text.troff, additional questions related
  298. to troff are shown below.  The remainder of the FAQ list is
  299. devoted to troff; bail out now if you are not interested.
  300.  
  301. ------------------------------
  302. Subject: TR2. How many varieties of troff are there? What are the differences?
  303.  
  304. The original Ossanna troff generates proprietary printer codes for the
  305. Wang C/A/T Phototypesetter; we'll call this "CAT Troff".  This version
  306. comes bundled in many systems, in particular, SunOS, most other
  307. Berkeley-derived systems, and is contained in the Xenix Text Processing
  308. package.  The AT&T, BSD and Xenix variants all differ slightly, but not
  309. in any important ways.  CAT troff is useless without filters to convert
  310. the "CAT codes" to something else, especially since the C/A/T is as
  311. common as a California condor.  These filters are described later.
  312.  
  313. In 1981, Brian Kernighan of Bell Laboratories rewrote troff to generate
  314. a generic typesetting language.  These troffs are called "ditroff" (for
  315. device-independent troff) and contain some additional features such as
  316. arbitrary line drawing, and more flexible font handling.  "Documenter's
  317. Workbench" (DWB) is a package containing ditroff and several other
  318. typesetting filters.  The latest AT&T version is DWB 3.3, which sold as
  319. source code; most commercial binary variants (Elan, SoftQuad, Image
  320. Network, etc.) are based on DWB 2.0.  The Free Software Foundation
  321. distributes a re-engineered version of ditroff called groff.
  322.  
  323. If you have a troff and want to know which it is, type:
  324.     troff < /dev/null > /dev/null
  325. If it responds with "typesetter busy" or "No /dev/cat; use -t or -a",
  326. you have CAT troff, otherwise it's ditroff.  If you get an answer from:
  327.     dwbv
  328. you have the AT&T release 3.0 or later.  The differences are too
  329. numerous and subtle to document here, but the variants are about
  330. 95% compatible.  All are ASCII based, but DWB 3.3, Groff and
  331. AIX 3.2's troff also accept ISO 8859-1 (aka ISO Latin 1), the
  332. Western European character set and are 8 bit clean.  Any 8-bit
  333. clean ditroff can be reconfigured to support alternate 8859-x
  334. character sets.  AIX 3.2 ditroff also supports Kanji (multi-byte)
  335. to a certain extent (as per IBM-932).
  336.  
  337. ------------------------------
  338. Subject: TR3. What are some of the filters for troff output?
  339.  
  340. Psroff is a suite of programs that allow you to translate CAT troff
  341. output or ditroff output format into PostScript, HP Laserjet (with
  342. incremental font downloading) or ditroff.  See description of hp2pbm
  343. below for driving printers other than these three.
  344.  
  345. Psroff works with all versions of CAT troff and ditroff, including
  346. groff.  Psroff allows you to change fonts on the fly (unlike any other
  347. CAT troff converter).  Psroff has been used to drive HP Laserjet and
  348. clone printers, PostScript (including Display PostScript and Sun
  349. Pageview), X windows previewers (such as xditview and xtroff),
  350. Ghostscript and many others.
  351.  
  352. Psroff comes with a large suite of utility programs that allow you to
  353. create, manipulate, display HP Laserjet and PostScript fonts, as well
  354. as construct width tables for these fonts from a variety of sources,
  355. including TeK PK format, HP SFP, and PostScript.  Psroff also comes
  356. with a number of other utilities, such as PostScript page reordering,
  357. Ascii-2-PostScript converters etc.  Psroff 3.0 is the only troff HP
  358. Laserjet filter fully supporting scalable fonts or HPGL/2 graphics on
  359. HP LJ III printers.
  360.  
  361. Psroff 3.0 is capable of performing some limited emulation of ditroff
  362. features (eg: line drawing) with CAT troff.
  363.  
  364. Psroff 3.0 is available from comp.sources.unix, volume 24.  Or from
  365. ftp.uunet.ca, in /distrib/chris_lewis/psroff3.0pl17 (fully patched).
  366. Patch level 17 is current.  The author is Chris Lewis,
  367. clewis@ferret.ocunix.on.ca.
  368.  
  369. Adobe Transcript is a commercial package similar to psroff, in that it
  370. contains filters for converting ditroff or CAT troff.  But only to
  371. PostScript.  It also contains filters for Ascii-2-PostScript, and is
  372. often installed as part of SunOS printcap filters.  Adobe Transcript
  373. contains a user interface script called "psroff" which should not be
  374. confused with the other psroff (but often is).  Information can be
  375. | acquired on its availability by contacting the Qualix group at
  376. | 1-800-245-UNIX, or info@qualix.com.  Supports psfig with a little
  377. hacking (instructions in psfig release).
  378.  
  379. The groff package from the Free-Software-Foundation includes drivers
  380. for PostScript, DVI, X and constant-width printers, and the complete
  381. suite of troff preprocessors with the exception of grap.  It is
  382. available via anonymous ftp from several sources (it needs the FSF C++
  383. or AT&T C++ 2.0 compilers to compile, but many binary versions are also
  384. available for FTP).  Supports character kerning (unlike CAT troff or
  385. DWB).  Does not contain an HP Laserjet driver.  A "dvi2lj" or psroff
  386. 3.0 can be used as a HP Laserjet driver for groff.  Groff has made some
  387. slight changes in the ditroff and width table formats, so use with
  388. non-groff drivers may need a little fiddling.  Written by James Clark.
  389. The latest version is 1.08.  The latest version can always be ftped
  390. from prep.ai.mit.edu:pub/gnu.
  391.  
  392. ------------------------------
  393. Subject: TR4. What other troff printer drivers are there?
  394.  
  395.     - thack: CAT to PostScript.   c.s.u. archives.
  396.       For very casual use only.  Has no width tables, and can't,
  397.       for example, make tbl box corners line up.)  Available from
  398.       c.s.u archives.  Very simple to build/install.
  399.  
  400.     - tpscript: ditroff to PostScript (reasonably good filter)
  401.       c.s.u archives.  Does not support psfig.
  402.  
  403.     - jetroff: ditroff to HP Laserjet (no support for III scalable
  404.       fonts).  Commercial version (jetroff 2) no longer available.
  405.       Jetroff 1.0 (shareware) is available from c.s.m archives.
  406.       Author: Rick Richardson.  Would need some fiddling to work
  407.       with groff.
  408.  
  409.     - troff2lj: CAT troff to HP Laserjet.  Limited font handling
  410.       functionality - package discontinued by author when psroff
  411.       2.0 was released.
  412.  
  413.     - lcat/lroff: obsolete, should be junked, precursor to psroff.
  414.  
  415.     - hp2pbm: not a troff-2-something filter per-se.  However,
  416.       given a HP Laserjet driver, hp2pbm can convert HP Laserjet
  417.       codes to Jef Poskanzer's PBM format, which permits you
  418.       to use any of the many output formats supported by PBM.
  419.       Author: Chris Lewis and Klaus Schallhorn.  Hp2pbm and PBM+
  420.       are accessible from c.s.m archives.  Hp2pbm includes a
  421.       24 pin Epson driver and a built-in G3 FAX driver.
  422.     
  423.     - cat2desk is a version of lcat/lroff modified to work with
  424.       Deskjets.  Psroff will work with newer deskjets (especially
  425.       scalable font ones with PCL4), but not older ones (the font
  426.       format is different) which are PCL3.
  427.  
  428. ------------------------------
  429. Subject: TR5. How do I get my troff to drive my printer?
  430.  
  431.     a) If you already have CAT troff and you don't need pic or grap:
  432.  
  433.        Your best bet is psroff if you want to drive printers supported
  434.        by psroff (PostScript, HP Laserjet, ditroff filters, PBM+
  435.        supported devices (including Epson 24 pin, FAX).  Transcript
  436.        is an alternative for PostScript output (but doesn't
  437.        allow you to mount fonts, no drawing support).
  438.  
  439.     b) You already have ditroff:
  440.  
  441.        You may already have a driver for your printer.  Check.
  442.        If not, your best bets are jetroff, psroff, tpscript,
  443.        transcript.
  444.     
  445.     c) You don't have a troff or, you have CAT troff and you need pic
  446.        and grap:
  447.  
  448.        Get "a DWB", such as groff (no grap), DWB 3, or one of the
  449.        commercial variants.
  450.  
  451. ------------------------------
  452. Subject: TR6. None of the mentioned packages support *my* printer.  Help?
  453.  
  454. This area is not entered into lightly. Look for a commercial or free
  455. package that supports your device.  Failing that, try to acquire
  456. (legally!) the source code for another device and modify it.  The AT&T
  457. documentation "Troff User's Manual" has a Reference section that
  458. completely documents the ditroff language.  SunOS and Psroff 3.0
  459. documentation contain descriptions of the CAT troff language.  Psroff
  460. 3.0 is designed for drop-in drivers, and may be the easiest to extend.
  461. Coupled with hp2pbm, psroff3.0 can probably drive just about any kind
  462. of printer that supports raster graphics with relatively little trouble
  463. (see Epson 24 pin driver for guidance).
  464.  
  465. If you can get a PostScript driver and are running on current SunOS,
  466. you could consider developing a NeWSprint driver for your printer.
  467. NeWSprint is Sun's NeWS (PostScript language interpreter extended for
  468. driving displays; not the same thing as "Display PostScript"(tm).  This
  469. may be easier than developing a troff driver, since all NeWSprint
  470. really needs is the ability to send a bitmap to a printer. Source and
  471. developer's documentation are shipped standard with NeWSprint.
  472.  
  473. Thack is ideal for quick hacks with CAT troff for printers that have
  474. dynamically scalable fonts (aside from the fact that thack has no
  475. facilities for building width tables).
  476.  
  477. ------------------------------
  478. Subject: TR7. How to I embed PostScript in troff?
  479.  
  480. There are two methods:
  481.  
  482.     - including "absolute" PostScript.  PostScript that knows where
  483.       it goes on the page, and decides its own scaling.
  484.       All versions of ditroff support this one way or another.
  485.       CAT troff does as well when coupled with psroff.  This is
  486.       most often supported by some permutation of \! or \X'...'
  487.       directives.
  488.  
  489.     - including PostScript, automatically scaling and placing the
  490.       image.  This requires that the PostScript be EPS (so that the
  491.       size and origin of the image is accessible).  Groff and
  492.       DWB 3.3 have facilities for including EPS files and automatically
  493.       placing/scaling them on the page, including leaving space in the
  494.       troff text for the image.  See if your documentation includes
  495.       remarks about "PSPIC", "PS" or other similar macros.
  496.  
  497.       Psfig (c.s.u archives) is a troff preprocessor which will permit
  498.       this sort of automatic placement/scaling with an older version
  499.       of ditroff (such as DWB 2.1) as long as the backend printer driver
  500.       understands it.  Psroff 3.0 and Adobe Transcript support psfig with
  501.       ditroff, but only Psroff 3.0 will support psfig with CAT troff.
  502.  
  503. Caution: many PC and MAC graphics packages generate sloppy PostScript which
  504. cannot be gracefully included in other documents.
  505.  
  506. ------------------------------
  507. Subject: TR8. What are fonts?  How do I add fonts?
  508.     
  509. A font is a set of characters in an specific typeface.  Unlike
  510. TeX, troff does not consider the same typeface at different
  511. sizes to be different fonts.
  512.  
  513. You have to make the width tables, install them, and tell the
  514. troff filter how to emit/request the fonts.  The details differ
  515. from one package to another.  Check the documentation.
  516.  
  517. ------------------------------
  518. Subject: TR9. What are width tables?
  519.  
  520. Both CAT troff and ditroff need to know the width of each character
  521. that you use.  The widths of each character (along with some additional
  522. characteristics) are arranged in a file for each font.  There are
  523. basically five different width table formats:
  524.  
  525.     1) CAT troff: uses a binary table of 224 unsigned chars.
  526.     2) MIPS (and RISC/Ultrix) CAT troff uses an ASCII dump of (1)
  527.     3) DWB 2.x and several of the commercial variants use an ASCII
  528.        format that is compiled into a binary form by a special program
  529.        called "makedev".
  530.     4) DWB 3.x uses the ASCII format mentioned in (3) - doesn't need
  531.        to be compiled.
  532.     5) Groff uses the ASCII format mentioned in (4) with minor variations.
  533.  
  534. If the width tables are wrong, character spacing will look funny - up
  535. to and including overlapping characters, and broken right justification.
  536.  
  537. ------------------------------
  538. Subject: TR10. How do I make width tables?
  539.  
  540. Creating them is not hard.  Getting the actual metrics sometimes is.
  541.  
  542. The AT&T documentation "Troff User's Manual" describes the DWB width
  543. table format.  Your DWB may already have a manual page for it.
  544.  
  545. Psroff 3.0 contains documentation on DWB and CAT troff format width
  546. tables.
  547.  
  548. DWB 3.3, Psroff 3.0 and tpscript each have a utility for automatically
  549. creating width tables by sucking the data out of a PostScript device.
  550.  
  551. Psroff 3.0 and jetroff have utilities for creating width tables from
  552. HP laserjet fonts.
  553.  
  554. Psroff 3.0 can convert between any of the 5 width table formats.
  555.  
  556. Consult the documentation to find out where to put the files.
  557.  
  558. ------------------------------
  559. Subject: TR11. What are: pic, eqn, tbl, grap, refer?
  560.  
  561. These are the basic troff preprocessors shipped with DWB:
  562.  
  563.     - pic allows you to draw arbitrary line-drawing graphics in a
  564.       machine-independent fashion.
  565.     - eqn allows you to construct mathmatical equations.
  566.     - tbl provides a mechanism for specifying and displaying
  567.       automatically sized/configured tables 
  568.     - grap uses pic to construct graphs.
  569.     - refer provides a mechanism for searching for and formatting
  570.       bibligraphic references.
  571.  
  572. Neither pic nor grap are included with CAT troff, but eqn, tbl and
  573. frequently refer are present.  Groff does not at present support grap.
  574.  
  575. ------------------------------
  576. Subject: TR12. How do I preview my troff on my screen?
  577.  
  578.     a) X windows: xditview and xtroff (X11R5 contrib directory, xtroff
  579.        also from ftp.cs.toronto.edu) and gxditview (from groff) will
  580.        preview ditroff format (groff requires gxditview), including
  581.        psroff 3.0's ditroff output from CAT troff.
  582.     b) Display PostScript (ie: AIX 3 & DEC dpsexec, NeXT,
  583.        Sun Pageview, Ultrascript, Ghostview plus GhostScript): any
  584.        PostScript generating troff.  (Theoretically at least.  May need
  585.        a teensy bit of PostScript hacking to get a reasonable pager
  586.        (psroff3.0 has this built in).  Pageview and Ultrascript have some
  587.        limitations so may not work with a specific PostScript
  588.        generator)
  589.     c) Others: You can probably find a PBM converter for it,
  590.        so use a Laserjet-generating troff configuration plus hp2pbm.
  591.        (eg: Sun rasters, 3b1 screens, EGA, VGA, GIFF, TIFF etc.)
  592.        I preview on X by generating PCL with psroff, converting
  593.        to PBM with hp2pbm, then display with pbm2Xd (part of hp2pbm)
  594.        and xwud (part of X windows).
  595.     d) Others: You may be able to find a DVI driver for it,
  596.        so use a DVI-generating troff configuration (namely,
  597.        groff's ditdvi) and use the appropriate dvi2<whatever> filter.
  598.     e) AIX 3.2 has a good AIXwindows 1.2 and Motif1.1 based
  599.        previewer called "xpreview".
  600.  
  601. ------------------------------
  602. Subject: TR13. I need makedev, but my DWB doesn't come with it.
  603.  
  604. A freeware version called "mkfont" is available from c.s.m, and
  605. is also included in Jetroff 1.0.  The Jetroff version is to be
  606. preferred because it's been extended a bit more to be an exact
  607. "makedev" replacement w.r.t. command line arguments.
  608.  
  609. ------------------------------
  610. Subject: TR14. Nroff/Troff on DOS machines
  611.  
  612. Arto Viitanen (av@ohdake.cs.uta.fi) has used djgpp (the MSDOS port of
  613. gcc 2.01) to compile groff-1.05 for MSDOS. The binaries are available
  614. at garbo.uwasa.fi in /pc/unix. The file is groff396.zip and it's 725 Kb.
  615. A port of version 1.07 by Mauro Condarelli is available from omnigate.
  616. clarkson.edu in pub/msdos/djgpp/pub.  This port includes the groff
  617. driver and also the dvi device, both of which were missing in the 1.05
  618. port.  Both ports work well except for gpic which does not seem to work on
  619. systems lacking a math coprocessor.
  620.  
  621. There's also a OS/2 port using the EMX environment (GCC 2.3.3), which
  622. includes a DOS extender.  The latest version may support DOS directly.
  623.  
  624. Elan, Image Network, and SoftQuad have commercial versions of DWB
  625. for DOS machines.  They tend to be a bit pricey - in the $500-$1200
  626. range.
  627.  
  628. There are many freeware versions of nroff that have either already
  629. been ported, or should be easy to port to DOS.  For example, C
  630. implementations of Kernighan and Plauger's "Software Tools" "roff"
  631. (see Ozan Yigit's implementation available from comp.sources.unix).
  632. [roff isn't a complete implementation of nroff, depends on what
  633. you need.]
  634.  
  635. Related: Ghostscript can be used on DOS to preview the output of any
  636. PostScript-producing application, including groff.  If you do use
  637. GhostScript, make sure that you get the latest version with the good
  638. fonts.  GhostScript also contains CGA and VGA drivers for on-screen
  639. preview.
  640.  
  641. Cawf2 a C port of Henry Spencer's Amazing Workable Formatter (originally
  642. an awk program).  It apparently does a reasonable job with -ms and -man
  643. macros.  The C version is by Vic Abell and is available from ftp.cc.
  644. purdue.edu in pucc/cawf.  It works on MSDOS and most or all UNIX systems.
  645.  
  646. I'd appreciate any other leads on DOS nroff/troffs.
  647.  
  648. ------------------------------
  649. Subject: TR15. What books can I get about DWB?
  650.  
  651. |    Troff User's Manual, by Ossanna and Kernighan, is available for
  652. |    anonymous ftp as netlib.att.com:/netlib/research/cstr/54.ps.Z.
  653.  
  654.     Document Formatting and Typesetting on the UNIX System,
  655.     2 volumes, Nerain Gehani, Silicon Press, ISBN 0-9615336-2-5.
  656.     A very good general reference; covers troff, the preprocessors,
  657.     and most of the popular macro packages.
  658.  
  659.     Typesetting Tables on the UNIX System, Henry McGilton, Mary McNabb.
  660.     Trilithon Press, ISBN 0-9626289-0-5.  A very good, very complete
  661.     reference and tutorial on TBL.
  662.  
  663.     Unix Text Processing, Dale Dougherty & Tim O'Reilly, Hayden Books,
  664.     ISBN 0-672-46291-5.  A good discussion not just of troff (ms & mm),
  665.     tbl, eqn, and pic, but also vi and ex, sed, and awk.
  666.  
  667.     Troff typesetting for Unix Systems, Sandra L. Emerson & Karen Paulsell
  668.     (kjp@well?) Prentice-Hall, 0-13-930959-4.  This is a good book
  669.     for people wishing to write raw troff (as in rolling your own
  670.     macros)
  671.  
  672.     troff-Programmierung: proffessionelle Textverarbeitung und
  673.         Schriftsatz unter UNIX, Claus Schirmer, Hanser Verlag 1990,
  674.         ISBN 3-446-15649-6.  Reportedly a superb book on troff
  675.     programming.  Ie: a ms-like macro package is built in a
  676.     step-by-step way.  Don't know if there's non-German language
  677.     version.
  678.  
  679.     The UNIX Text Processing System, Kaare Christian, Wiley, 1987.
  680.     Is especially good on REFER, the best chapter on REFER
  681.     available.  [This book now appears to be out of print.]
  682.  
  683.     Text processing and typesetting with UNIX, D.W. Barron and Mike Rees,
  684.     Addison-Wesley, 1987.
  685. -- 
  686. Chris Lewis: _Una confibula non sat est_
  687. Phone: Canada 613 832-0541  Ferret list: ferret-request@ferret.ocunix.on.ca
  688. Latest psroff: FTP://ftp.uunet.ca/distrib/chris_lewis/psroff3.0pl17/*
  689. Latest hp2pbm: FTP://ftp.uunet.ca/distrib/chris_lewis/hp2pbm/*
  690.